<?php
require_once 'classdb.php';
class seo_tour extends db {    
    public function seo($view,$id=-1,$lang)
    {
        $array= array();
        if($view=='dichvu_chitiet')
        {            
		   $seo=$this->get_by_thutu("dichvu",$id,1);
           $row_seo=mysql_fetch_assoc($seo);
           $array['title']=$row_seo['ten_'.$lang];
           return $array;
        }
		else if($view=='chamsocda_chitiet')
        {            
		   $seo=$this->get_by_thutu("chamsocda",$id,1);
           $row_seo=mysql_fetch_assoc($seo);
           $array['title']=$row_seo['ten_'.$lang];
           return $array;
        }
        else if($view=='sanpham_chitiet')
        {
         	$seo=$this->get_by_thutu("sanpham",$id,1);
           $row_seo=mysql_fetch_assoc($seo);
           $array['title']=$row_seo['ten_'.$lang];
           return $array;
        }
		else if($view=='tuvan_chitiet')
        {            
		   $seo=$this->get_by_thutu("tuvan",$id,1);
           $row_seo=mysql_fetch_assoc($seo);
           $array['title']=$row_seo['ten_'.$lang];
           return $array;
        }
        else if($view=='machine_chitiet')
        {
         	$seo=$this->get_by_thutu("sanpham",$id,1);
           $row_seo=mysql_fetch_assoc($seo);
           $array['title']=$row_seo['ten_'.$lang];
           return $array;
        }
		
		else if($view=='lienhe')
        {
           if($lang=='vi') $array['title']='Liên hệ';
			else $array['title']='Contact';
           return $array;
        } 
		else if($view=='quitrinhtrimun')
        {
           if($lang=='vi') $array['title']='Qui trình trị mụn';
			else $array['title']='Contact';
           return $array;
        } 
		
		 else if($view=='sanpham_all')
        {
           $array['title']='Danh sách sản phẩm';
           return $array;
        }
		 else if($view=='dichvu_all')
        {
           $array['title']='Danh sách dịch vụ';
           return $array;
        }
		 else if($view=='chamsocda_all')
        {
           $array['title']='Chăm sóc da';
           return $array;
        }
		 else if($view=='tuvan')
        {
           $array['title']='Tư vấn';
           return $array;
        }
		 else if($view=='tintuc_all')
        {
           if($lang=='vi') $array['title']='Danh sách tin tức';
			else $array['title']='News';
           return $array;
        }
		 else if($view=='tintuc_chitiet')
        {
           $seo=$this->get_by_thutu("tintuc",$id,1);
           $row_seo=mysql_fetch_assoc($seo);
           $array['title']=$row_seo['ten_'.$lang];
           return $array;
        }
		else if(!isset($_GET['view']))
        {
           $array['title']='Thẩm mỹ an an';
           return $array;
        }
    }
}
?>